<!DOCTYPE html>
<html lang="zh-CN">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>TickTock - 极简半透明抽屉式布局</title>
    <style>
        * {
            margin: 0;
            padding: 0;
            box-sizing: border-box;
            font-family: "PingFang SC", "Microsoft YaHei", sans-serif;
        }
        
        body {
            background-color: #f8f8f8;
            color: #333;
            height: 100vh;
            overflow: hidden;
        }
        
        .app-container {
            display: flex;
            height: 100vh;
            position: relative;
            overflow: hidden;
        }
        
        /* 抽屉部分 */
        .drawer {
            width: 280px;
            height: 100%;
            background-color: rgba(255, 255, 255, 0.95);
            box-shadow: 0 0 20px rgba(0, 0, 0, 0.1);
            transform: translateX(-280px);
            transition: transform 0.3s ease;
            position: absolute;
            z-index: 10;
            overflow-y: auto;
            border-right: 1px solid rgba(0, 0, 0, 0.05);
            padding-bottom: 60px;
        }
        
        .drawer.open {
            transform: translateX(0);
        }
        
        .drawer-header {
            padding: 20px 16px;
            border-bottom: 1px solid rgba(0, 0, 0, 0.05);
            font-size: 18px;
            font-weight: 600;
            color: #333;
            background-color: #fff;
            position: sticky;
            top: 0;
            z-index: 1;
        }
        
        .list-item {
            padding: 16px;
            border-bottom: 1px solid rgba(0, 0, 0, 0.05);
            display: flex;
            align-items: center;
            justify-content: space-between;
            cursor: pointer;
        }
        
        .list-item:hover {
            background-color: rgba(0, 0, 0, 0.02);
        }
        
        .list-item.active {
            background-color: rgba(66, 133, 244, 0.08);
            border-left: 3px solid #4285f4;
        }
        
        .list-title {
            display: flex;
            align-items: center;
            gap: 10px;
        }
        
        .list-icon {
            width: 20px;
            height: 20px;
            display: flex;
            align-items: center;
            justify-content: center;
            color: #666;
        }
        
        .list-count {
            font-size: 12px;
            color: #999;
            background-color: rgba(0, 0, 0, 0.05);
            padding: 2px 8px;
            border-radius: 10px;
        }
        
        .sub-list {
            padding-left: 20px;
            max-height: 0;
            overflow: hidden;
            transition: max-height 0.3s ease;
        }
        
        .list-item.expanded + .sub-list {
            max-height: 500px;
        }
        
        .add-list-btn {
            position: absolute;
            bottom: 0;
            width: 100%;
            padding: 16px;
            background-color: #fff;
            border-top: 1px solid rgba(0, 0, 0, 0.05);
            display: flex;
            align-items: center;
            justify-content: center;
            gap: 8px;
            color: #4285f4;
            font-weight: 500;
            cursor: pointer;
        }
        
        /* 主内容区 */
        .main-content {
            flex: 1;
            padding: 16px;
            margin-left: 0;
            transition: margin-left 0.3s ease;
            height: 100%;
            overflow-y: auto;
            position: relative;
        }
        
        .main-content.drawer-open {
            margin-left: 280px;
        }
        
        .header {
            display: flex;
            align-items: center;
            justify-content: space-between;
            padding: 16px 0;
            margin-bottom: 20px;
            border-bottom: 1px solid rgba(0, 0, 0, 0.1);
        }
        
        .menu-btn {
            width: 24px;
            height: 24px;
            cursor: pointer;
            display: flex;
            flex-direction: column;
            justify-content: space-between;
            padding: 5px 0;
        }
        
        .menu-btn span {
            display: block;
            height: 2px;
            width: 100%;
            background-color: #333;
            border-radius: 2px;
            transition: all 0.3s ease;
        }
        
        .menu-btn.active span:first-child {
            transform: translateY(6px) rotate(45deg);
        }
        
        .menu-btn.active span:nth-child(2) {
            opacity: 0;
        }
        
        .menu-btn.active span:last-child {
            transform: translateY(-6px) rotate(-45deg);
        }
        
        .title {
            flex: 1;
            text-align: center;
            font-size: 18px;
            font-weight: 600;
        }
        
        .actions {
            display: flex;
            gap: 16px;
        }
        
        .section-title {
            font-size: 16px;
            font-weight: 600;
            margin: 24px 0 12px 0;
            color: #666;
        }
        
        .task-list {
            display: flex;
            flex-direction: column;
            gap: 12px;
        }
        
        .task-item {
            background-color: #fff;
            border-radius: 12px;
            padding: 16px;
            box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
            display: flex;
            flex-direction: column;
            gap: 8px;
            transition: transform 0.2s ease, box-shadow 0.2s ease;
            cursor: pointer;
        }
        
        .task-item:hover {
            transform: translateY(-2px);
            box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
        }
        
        .task-header {
            display: flex;
            align-items: center;
            gap: 12px;
        }
        
        .task-checkbox {
            width: 20px;
            height: 20px;
            border-radius: 50%;
            border: 2px solid #ddd;
            display: flex;
            align-items: center;
            justify-content: center;
            cursor: pointer;
        }
        
        .task-checkbox.checked {
            background-color: #4285f4;
            border-color: #4285f4;
        }
        
        .task-checkbox.checked::after {
            content: "✓";
            color: white;
            font-size: 12px;
        }
        
        .task-title {
            font-size: 16px;
            font-weight: 500;
            flex: 1;
        }
        
        .task-info {
            display: flex;
            align-items: center;
            gap: 8px;
            margin-left: 32px;
            font-size: 12px;
            color: #999;
        }
        
        .priority {
            padding: 2px 8px;
            border-radius: 4px;
            font-weight: 500;
        }
        
        .priority.high {
            background-color: rgba(244, 67, 54, 0.1);
            color: #f44336;
        }
        
        .priority.medium {
            background-color: rgba(255, 152, 0, 0.1);
            color: #ff9800;
        }
        
        .priority.low {
            background-color: rgba(76, 175, 80, 0.1);
            color: #4caf50;
        }
        
        .task-date {
            display: flex;
            align-items: center;
            gap: 4px;
        }
        
        .bottom-bar {
            position: fixed;
            bottom: 0;
            left: 0;
            right: 0;
            height: 56px;
            background-color: #fff;
            display: flex;
            align-items: center;
            justify-content: space-around;
            box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.05);
            z-index: 5;
        }
        
        .tab {
            flex: 1;
            display: flex;
            flex-direction: column;
            align-items: center;
            justify-content: center;
            height: 100%;
            color: #999;
            font-size: 12px;
            gap: 4px;
            cursor: pointer;
        }
        
        .tab.active {
            color: #4285f4;
        }
        
        .tab-icon {
            font-size: 20px;
        }
        
        .add-btn {
            width: 56px;
            height: 56px;
            background-color: #4285f4;
            border-radius: 50%;
            color: white;
            display: flex;
            align-items: center;
            justify-content: center;
            font-size: 24px;
            box-shadow: 0 4px 10px rgba(66, 133, 244, 0.3);
            cursor: pointer;
            position: relative;
            top: -20px;
        }
        
        /* 半透明遮罩 */
        .overlay {
            position: fixed;
            top: 0;
            left: 0;
            right: 0;
            bottom: 0;
            background-color: rgba(0, 0, 0, 0.3);
            z-index: 5;
            opacity: 0;
            pointer-events: none;
            transition: opacity 0.3s ease;
        }
        
        .overlay.active {
            opacity: 1;
            pointer-events: auto;
        }
        
        @media (max-width: 768px) {
            .drawer {
                width: 85%;
                max-width: 300px;
            }
            
            .main-content.drawer-open {
                margin-left: 0;
            }
        }
    </style>
</head>
<body>
    <div class="app-container">
        <!-- 抽屉菜单 -->
        <div class="drawer" id="drawer">
            <div class="drawer-header">我的清单</div>
            
            <div class="list-item">
                <div class="list-title">
                    <div class="list-icon">📊</div>
                    <div>工作清单</div>
                </div>
                <div class="list-count">5/12</div>
            </div>
            
            <div class="list-item">
                <div class="list-title">
                    <div class="list-icon">📚</div>
                    <div>学习清单</div>
                </div>
                <div class="list-count">2/8</div>
            </div>
            
            <div class="list-item expanded">
                <div class="list-title">
                    <div class="list-icon">🏠</div>
                    <div>个人清单</div>
                </div>
                <div class="list-count">3/10</div>
            </div>
            
            <div class="sub-list">
                <div class="list-item">
                    <div class="list-title">
                        <div class="list-icon">📝</div>
                        <div>日常事务</div>
                    </div>
                    <div class="list-count">1/3</div>
                </div>
                
                <div class="list-item active">
                    <div class="list-title">
                        <div class="list-icon">💪</div>
                        <div>健康习惯</div>
                    </div>
                    <div class="list-count">2/4</div>
                </div>
                
                <div class="list-item">
                    <div class="list-title">
                        <div class="list-icon">✈️</div>
                        <div>旅行计划</div>
                    </div>
                    <div class="list-count">0/3</div>
                </div>
            </div>
            
            <div class="list-item">
                <div class="list-title">
                    <div class="list-icon">🛒</div>
                    <div>购物清单</div>
                </div>
                <div class="list-count">1/5</div>
            </div>
            
            <div class="add-list-btn">
                <span>+</span>
                <span>新建清单</span>
            </div>
        </div>
        
        <!-- 半透明遮罩 -->
        <div class="overlay" id="overlay"></div>
        
        <!-- 主内容区 -->
        <div class="main-content" id="main-content">
            <div class="header">
                <div class="menu-btn" id="menu-btn">
                    <span></span>
                    <span></span>
                    <span></span>
                </div>
                <div class="title">健康习惯 - 任务 (2/4)</div>
                <div class="actions">
                    <div class="search-icon">🔍</div>
                    <div class="more-icon">⋮</div>
                </div>
            </div>
            
            <div class="section-title">待办</div>
            <div class="task-list">
                <div class="task-item">
                    <div class="task-header">
                        <div class="task-checkbox"></div>
                        <div class="task-title">每日喝水2L</div>
                    </div>
                    <div class="task-info">
                        <div class="priority high">优先级：高</div>
                        <div class="task-date">🕒 今天</div>
                    </div>
                </div>
                
                <div class="task-item">
                    <div class="task-header">
                        <div class="task-checkbox"></div>
                        <div class="task-title">冥想练习</div>
                    </div>
                    <div class="task-info">
                        <div class="priority low">优先级：低</div>
                        <div class="task-date">🕒 明天</div>
                    </div>
                </div>
            </div>
            
            <div class="section-title">已完成</div>
            <div class="task-list">
                <div class="task-item">
                    <div class="task-header">
                        <div class="task-checkbox checked"></div>
                        <div class="task-title" style="text-decoration: line-through; color: #999;">晨跑30分钟</div>
                    </div>
                    <div class="task-info">
                        <div class="priority medium">优先级：中</div>
                        <div class="task-date">🕒 今天</div>
                    </div>
                </div>
                
                <div class="task-item">
                    <div class="task-header">
                        <div class="task-checkbox checked"></div>
                        <div class="task-title" style="text-decoration: line-through; color: #999;">健康饮食</div>
                    </div>
                    <div class="task-info">
                        <div class="priority medium">优先级：中</div>
                        <div class="task-date">🕒 昨天</div>
                    </div>
                </div>
            </div>
        </div>
        
        <!-- 底部导航栏 -->
        <div class="bottom-bar">
            <div class="tab">
                <div class="tab-icon">📋</div>
                <div>清单</div>
            </div>
            <div class="tab">
                <div class="tab-icon">📅</div>
                <div>今日</div>
            </div>
            <div class="add-btn">+</div>
            <div class="tab">
                <div class="tab-icon">📊</div>
                <div>统计</div>
            </div>
            <div class="tab">
                <div class="tab-icon">👤</div>
                <div>我的</div>
            </div>
        </div>
    </div>
    
    <script>
        const menuBtn = document.getElementById('menu-btn');
        const drawer = document.getElementById('drawer');
        const mainContent = document.getElementById('main-content');
        const overlay = document.getElementById('overlay');
        
        menuBtn.addEventListener('click', () => {
            menuBtn.classList.toggle('active');
            drawer.classList.toggle('open');
            mainContent.classList.toggle('drawer-open');
            overlay.classList.toggle('active');
        });
        
        overlay.addEventListener('click', () => {
            menuBtn.classList.remove('active');
            drawer.classList.remove('open');
            mainContent.classList.remove('drawer-open');
            overlay.classList.remove('active');
        });
        
        // 简单的抽屉内项目展开/折叠功能
        const listItems = document.querySelectorAll('.list-item');
        listItems.forEach(item => {
            if (!item.parentElement.classList.contains('sub-list')) {
                item.addEventListener('click', () => {
                    if (item.nextElementSibling && item.nextElementSibling.classList.contains('sub-list')) {
                        item.classList.toggle('expanded');
                    }
                });
            }
        });
    </script>
</body>
</html> 